<!--交易记录-->

<template>
  <div>
    <div class="my_header">
      <i class="mui-icon mui-icon-arrowleft" aria-hidden="true" @click="$router.back(-1)"></i>
      <div class="top1">提现详情</div>

    </div>
    <div class="jyrecord">

      <div class="row">
        <div class="left">申请时间</div>
        <div class="right">{{buyddetail.add_time}}</div>
      </div>
      <div class="row">
        <div class="left">流水号</div>
        <div class="right">{{buyddetail.order_no}}</div>
      </div>
      <div class="row">
        <div class="left">提现金额</div>
        <div class="right">￥{{buyddetail.money}}</div>
      </div>
      <div class="row" v-if="buyddetail.type=='支付宝'">
        <div class="left">支付宝账号</div>
        <div class="right">{{buyddetail.alipay}}</div>
      </div>

      <div class="row">
        <div class="left">状态</div>
        <div class="right">{{buyddetail.state}}</div>
      </div>
      <div class="row" v-if="buyddetail.type=='银行卡'">
        <div class="left">开户行</div>
        <div class="right">{{buyddetail.bank}}</div>
      </div>
      <div class="row" v-if="buyddetail.type=='银行卡'">
        <div class="left">银行账户</div>
        <div class="right">{{buyddetail.card}}</div>
      </div>

    </div>

  </div>

</template>

<script>
  export default {

    data() {
      return {
        buyddetail: {},
      };
    },
    created: function () {
      var token = localStorage.getItem("token");
      var that = this;
      var buyid = this.$route.query.tabitem;
      that.getbuydetail(buyid);
    },
    methods: {
      getbuydetail(buyid) {
        console.log(buyid);
        var that = this;
        $.ajax({
          type: "get",
          url: "http://zcapi.hrgsxt.cn/api/User_account/info",
          data: {
            token: localStorage.getItem("token"),
            withdrwalt_id: buyid
          },
          cache: false,
          dataType: "json",
          success: function (data) {
            console.log("哈哈", data);
            if (data.code == 200) {

              that.buyddetail = data.data;
            } else {

              that.$toast({
                message: data.message,
                duration: 1000
              })

            }

          }
        });
      }

    },

    watch: {
      // 如果路由有变化，会再次执行该方法
      '$route': 'fetchData'
    }
  }

  //图片上传并预览
</script>

<style scoped="scoped">
  /*头部*/
  .my_header {
    height: .88rem;
    background: rgba(0, 133, 240, 1);
    text-align: center;
    color: #fff;
    line-height: .88rem;
    position: relative;
    padding: 0 .3rem;
  }

  /*.jyje .right{
         color: #FF7E00 !important;
  }*/

  .my_header i {
    font-size: .4rem;
    float: left;
    line-height: .88rem;
  }

  .my_header .top1 {
    width: 40%;
    margin-left: 25%;
    float: left;
    text-align: center;
  }

  /*查询记录*/
  .jyrecord {
    margin-top: 0px !important;
    width: 100%;
    font-size: 0.26rem !important;
    background-color: #FFFFFF;
  }

  .jyrecord .row {
    width: 100%;
    height: 0.88rem;
    background-color: #FFFFFF;
    line-height: 0.88rem;
    padding: 0px 0.3rem 0px 0.3rem;
    border-bottom: 1px solid #efefef;
  }

  .jyrecord .row:first-child {
    border-bottom: 1px solid #efefef;
  }

  .jyrecord .row .left {
    width: 50%;
    float: left;
    font-size: 0.3rem;
    color: #333333;
  }

  .jyrecord .row .right {
    color: #666666;
    width: 50%;
    float: right;
    font-size: 0.28rem;
    line-height: 0.88rem;
    text-align: right;
  }

  .jyrecord .row .right img {
    width: 0.14rem;
    height: 0.24rem;
    vertical-align: middle;
    margin-left: 7px;
    margin-bottom: 3px;
  }

  .jyrecord .row .right input {
    border: none;
    outline: none;
    text-indent: 4em;
    text-align: right;
    padding-right: 0px !important;
  }

</style>
